package com.lxp.userms.mapper;

import com.lxp.userms.entity.Question;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface QuestionMapper {
    int insertQuestion(Question question);
    Question selectQuestionById(int id);
    List<Question> selectAllQuestions();
    List<Question> selectQuestionsByUserId(int userId);
    List<Question> selectQuestionsByExpertId(int expertId);
    List<Question> selectQuestionsByCategoryId(int categoryId);
    int updateQuestion(Question question);
    int deleteQuestion(int id);
    int deleteQuestionsByCategoryId(int categoryId);
}